/**
 * 启用npm run api读取scripts/api/build.js文件，创建接口模块
 * 重写swagger-to-service调用方式
 */
// 当前文件夹的目录 const path = require("path");
const config = require("../../src/utils/apiconfig"); //配置api生成的目录路径
const sts = require("swagger-to-service");
const plugin = require("./plugin");
sts({
  url: config.pathYaml,
  apiPath: config.apiPath,
  servicePath: config.servicePath,
  plugins: [plugin] //易错点plugins而不是plugin
});
